@extends('shared.adminBase')
@section('title','兑换详情')
@section('content')
    <section class="content-header">
        <h1>兑换详情</h1>
        <ol class="breadcrumb">
            <li><a href="{{URL::action('AdminController@innerIndex')}}"><i class="fa fa-dashboard"></i> 首页</a>
            </li>
            <li class="active">兑换详情</li>
        </ol>
    </section>
    <section class="content">
        <div class="row">
            <div class="col-xs-12">
                <!-- /.box -->
                <div class="box">
                    <!-- /.box-header -->
                    <div class="box-body col-md-12">
                        <form id="form1" action="{{URL::action('GameController@updateExchangeRecord')}}"
                              method="post" enctype="multipart/form-data">
                            {{csrf_field()}}
                            <input type="hidden" name="id" value="{{$record->exchange_record_id}}">
                            <div class="form-group">
                          <table style="border-collapse:separate; border-spacing:0px 10px;">
                              <tr>
                                  <td style="text-align:right;">订单号：</td>
                                  <td style="text-align:left;">{{$record->exchange_record_id }}</td>
                              </tr>
                              <tr>
                                  <td style="text-align:right;">订单时间：</td>
                                  <td style="text-align:left;">{{$record->create_date }}</td>
                              </tr>
                              <tr>
                                  <td style="text-align:right;">商品名称：</td>
                                  <td style="text-align:left;">{{$record->product_name }}</td>
                              </tr>
                              <tr>
                                  <td style="text-align:right;">用户ID：</td>
                                  <td style="text-align:left;">{{$record->user_id }}</td>
                              </tr>
                              <tr>
                                  <td style="text-align:right;">手机号：</td>
                                  <td style="text-align:left;">{{$record->contact_phone }}</td>
                              </tr>
                              <tr>
                                  <td style="text-align:right;">收件人：</td>
                                  <td style="text-align:left;">{{$record->receive_name }}</td>
                              </tr>
                              <tr>
                                  <td style="text-align:right;">地址：</td>
                                  <td style="text-align:left;">{{$record->receive_address }}</td>
                              </tr>
                              <tr>
                                  <td style="text-align:right;">状态：</td>
                                  <td style="text-align:left;"> <select name="status">
                                          @foreach(App\Framework\Enum\ExchangeRecordStatusEnum::$dataMap as $k=>$v)
                                              @if($k==$record->status)
                                                  <option value="{{$k}}" selected="selected">{{$v}}</option>
                                              @else
                                                  <option value="{{$k}}">{{$v}}</option>
                                              @endif
                                          @endforeach
                                      </select></td>
                              </tr>
                              <tr>
                                  <td style="text-align:right;">备注：</td>
                                  <td style="text-align:left;"><textarea rows="5" cols="50" name="comment" placeholder="填写快递单号，或者平台订单号，填写用户反馈信息等。">{{$record->comment}}</textarea></td>
                              </tr>
                          </table>
                            </div>
                            <div class="form-group">
                                <button type="submit" class="btn btn-default">提交</button>
                                <button type="button" onclick="history.back();" class="btn btn-default">返回</button>
                            </div>
                        </form>
                    </div>
                    <!-- /.box-body -->
                </div>
                <!-- /.box -->
            </div>
            <!-- /.col -->
        </div>
        <!-- /.row -->
    </section>

@endsection